import { UserLayout, BasicLayout, RouteView, BlankLayout, PageView, BlogLayout, BlogDetailLayout } from '@/layouts'
import { bxAnaalyse } from '@/core/icons'
import { RouterMockData } from '@/mock/services/routerData'

/**
 * 基础路由
 * @type { *[] }
 */
export const constantRouterMap = [
  /*博客相关路由*/
  {
    path: '/',
    component: BlogLayout,
    name: 'Index',
    redirect: '/blog/index',
    children: [{
      path: '/blog/index',
      name: 'BlogIndex',
      component: () => import('@/views/blog/BlogIndex')
    }, {
      path: '/blog/architect',
      name: 'BlogArchitect',
      component: () => import(/* webpackChunkName: "constant-component" */ '@/views/blog/BlogArchitect')
    }, {
      path: '/blog/leaveMsg',
      name: 'BlogCommentDrawer',
      component: () => import(/* webpackChunkName: "constant-component" */'@/views/blog/BlogComment')
    }
    ]
  },
  {
    path: '/blog/page',
    component: BlogDetailLayout,
    children: [
      {
        path: '/blog/page/:blogId',
        name: 'BlogDetail',
        component: () => import(/* webpackChunkName: "constant-component" */'@/views/blog/BlogContent')
      }
    ]
  },
  {
    path: '/test',
    component: BlankLayout,
    redirect: '/test/home',
    children: [
      {
        path: 'home',
        name: 'TestHome',
        component: () => import(/* webpackChunkName: "constant-component" */'@/views/Home')
      }, {
        path: 'navbar',
        name: 'TestNavbar',
        component: () => import(/* webpackChunkName: "constant-component" */'@/views/demo/NavBarDemo')
      },{
        path: 'MenueDemo',
        name: 'MenueDemo',
        component: () => import(/* webpackChunkName: "constant-component" */'@/views/demo/MenueDemo')
      }, {
        path: 'MockJsDemo',
        name: 'MockJsDemo',
        component: () => import(/* webpackChunkName: "constant-component" */'@/views/demo/MockJsDemo')
      }
    ]
  },
  {
    path: '/user',
    component: UserLayout,
    redirect: '/user/login',
    hidden: true,
    children: [
      {
        path: 'login',
        name: 'login',
        component: () => import(/* webpackChunkName: "user-component" */ '@/views/user/Login')
      },
      {
        path: 'register',
        name: 'register',
        component: () => import(/* webpackChunkName: "user-component" */ '@/views/user/Register')
      },
      {
        path: 'register-result',
        name: 'registerResult',
        component: () => import(/* webpackChunkName: "user-component" */ '@/views/user/RegisterResult')
      },
      {
        path: 'recover',
        name: 'recover',
        component: undefined
      }
    ]
  },
  {
    path: '/user/loginSuccess',
    name: 'LoginSuccess',
    component: () => import(/* webpackChunkName: "constant-component" */'@/views/blog/LoginSuccess.vue')
  },
  {
    path: '/404',
    component: () => import(/* webpackChunkName: "constant-component" */'@/views/exception/404')
  }
]


